package org.microdream.easy.deploy.po;

import ice.server.comm.PoExtender;

import javax.persistence.*;
import java.io.Serializable;
import java.sql.Timestamp;
import java.util.Objects;

@Entity
@Table(name = "d_user", schema = "easydeploy", catalog = "")
public class DUser  extends PoExtender implements Serializable {
    private static final long serialVersionUID = 1L;
    private Integer id;
    private String userAccount;
    private String userName;
    private String realName;
    private Integer userSex;
    private String userPassword;
    private String userIdNumber;
    private String userBirthday;
    private String userNative;
    private String userEmail;
    private String userQqNumber;
    private String userPhone;
    private Integer isMarry;
    private String userContacts;
    private String userAddress;
    private String rentCode;
    private Integer isLock;
    private String createUser;
    private Timestamp createTime;
    private String updateUser;
    private Timestamp updateTime;
    private Integer sourceType;
    private Integer isDelete;
    private Integer isGod;

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "id")
    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    @Basic
    @Column(name = "user_account")
    public String getUserAccount() {
        return userAccount;
    }

    public void setUserAccount(String userAccount) {
        this.userAccount = userAccount;
    }

    @Basic
    @Column(name = "user_name")
    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    @Basic
    @Column(name = "real_name")
    public String getRealName() {
        return realName;
    }

    public void setRealName(String realName) {
        this.realName = realName;
    }

    @Basic
    @Column(name = "user_sex")
    public Integer getUserSex() {
        return userSex;
    }

    public void setUserSex(Integer userSex) {
        this.userSex = userSex;
    }

    @Basic
    @Column(name = "user_password")
    public String getUserPassword() {
        return userPassword;
    }

    public void setUserPassword(String userPassword) {
        this.userPassword = userPassword;
    }

    @Basic
    @Column(name = "user_id_number")
    public String getUserIdNumber() {
        return userIdNumber;
    }

    public void setUserIdNumber(String userIdNumber) {
        this.userIdNumber = userIdNumber;
    }

    @Basic
    @Column(name = "user_birthday")
    public String getUserBirthday() {
        return userBirthday;
    }

    public void setUserBirthday(String userBirthday) {
        this.userBirthday = userBirthday;
    }

    @Basic
    @Column(name = "user_native")
    public String getUserNative() {
        return userNative;
    }

    public void setUserNative(String userNative) {
        this.userNative = userNative;
    }

    @Basic
    @Column(name = "user_email")
    public String getUserEmail() {
        return userEmail;
    }

    public void setUserEmail(String userEmail) {
        this.userEmail = userEmail;
    }

    @Basic
    @Column(name = "user_qq_number")
    public String getUserQqNumber() {
        return userQqNumber;
    }

    public void setUserQqNumber(String userQqNumber) {
        this.userQqNumber = userQqNumber;
    }

    @Basic
    @Column(name = "user_phone")
    public String getUserPhone() {
        return userPhone;
    }

    public void setUserPhone(String userPhone) {
        this.userPhone = userPhone;
    }

    @Basic
    @Column(name = "is_marry")
    public Integer getIsMarry() {
        return isMarry;
    }

    public void setIsMarry(Integer isMarry) {
        this.isMarry = isMarry;
    }

    @Basic
    @Column(name = "user_contacts")
    public String getUserContacts() {
        return userContacts;
    }

    public void setUserContacts(String userContacts) {
        this.userContacts = userContacts;
    }

    @Basic
    @Column(name = "user_address")
    public String getUserAddress() {
        return userAddress;
    }

    public void setUserAddress(String userAddress) {
        this.userAddress = userAddress;
    }

    @Basic
    @Column(name = "rent_code")
    public String getRentCode() {
        return rentCode;
    }

    public void setRentCode(String rentCode) {
        this.rentCode = rentCode;
    }

    @Basic
    @Column(name = "is_lock")
    public Integer getIsLock() {
        return isLock;
    }

    public void setIsLock(Integer isLock) {
        this.isLock = isLock;
    }

    @Basic
    @Column(name = "create_user")
    public String getCreateUser() {
        return createUser;
    }

    public void setCreateUser(String createUser) {
        this.createUser = createUser;
    }

    @Basic
    @Column(name = "create_time")
    public Timestamp getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }

    @Basic
    @Column(name = "update_user")
    public String getUpdateUser() {
        return updateUser;
    }

    public void setUpdateUser(String updateUser) {
        this.updateUser = updateUser;
    }

    @Basic
    @Column(name = "update_time")
    public Timestamp getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Timestamp updateTime) {
        this.updateTime = updateTime;
    }

    @Basic
    @Column(name = "source_type")
    public Integer getSourceType() {
        return sourceType;
    }

    public void setSourceType(Integer sourceType) {
        this.sourceType = sourceType;
    }

    @Basic
    @Column(name = "is_delete")
    public Integer getIsDelete() {
        return isDelete;
    }

    public void setIsDelete(Integer isDelete) {
        this.isDelete = isDelete;
    }

    @Basic
    @Column(name = "is_god")
    public Integer getIsGod() {
        return isGod;
    }

    public void setIsGod(Integer isGod) {
        this.isGod = isGod;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        DUser dUser = (DUser) o;
        return id == dUser.id &&
                Objects.equals(userAccount, dUser.userAccount) &&
                Objects.equals(userName, dUser.userName) &&
                Objects.equals(realName, dUser.realName) &&
                Objects.equals(userSex, dUser.userSex) &&
                Objects.equals(userPassword, dUser.userPassword) &&
                Objects.equals(userIdNumber, dUser.userIdNumber) &&
                Objects.equals(userBirthday, dUser.userBirthday) &&
                Objects.equals(userNative, dUser.userNative) &&
                Objects.equals(userEmail, dUser.userEmail) &&
                Objects.equals(userQqNumber, dUser.userQqNumber) &&
                Objects.equals(userPhone, dUser.userPhone) &&
                Objects.equals(isMarry, dUser.isMarry) &&
                Objects.equals(userContacts, dUser.userContacts) &&
                Objects.equals(userAddress, dUser.userAddress) &&
                Objects.equals(rentCode, dUser.rentCode) &&
                Objects.equals(isLock, dUser.isLock) &&
                Objects.equals(createUser, dUser.createUser) &&
                Objects.equals(createTime, dUser.createTime) &&
                Objects.equals(updateUser, dUser.updateUser) &&
                Objects.equals(updateTime, dUser.updateTime) &&
                Objects.equals(sourceType, dUser.sourceType) &&
                Objects.equals(isDelete, dUser.isDelete) &&
                Objects.equals(isGod, dUser.isGod);
    }

    @Override
    public int hashCode() {
        return Objects.hash(id, userAccount, userName, realName, userSex, userPassword, userIdNumber, userBirthday, userNative, userEmail, userQqNumber, userPhone, isMarry, userContacts, userAddress, rentCode, isLock, createUser, createTime, updateUser, updateTime, sourceType, isDelete, isGod);
    }
}
